<?php

namespace apiend\modules\user\controllers;

use Yii;
use apiend\components\Controller;
use apiend\modules\user\models\UserProfileSearch;

/**
 * 个人主页相关接口
 * 
 * @author emhome <emhome@163.com>
 * @since 1.0
 */
class HomeController extends Controller {

    /**
     * @inheritdoc
     */
    public function actionIndex() {
        $model = new UserProfileSearch();
        if (!$model->load(Yii::$app->request->getQueryParams(), '')) {
            return parent::error('查询失败，缺少必要的检索用户信息');
        }
        return $model->search();
    }

}
